package com.renwei.sample.controller;

import org.apache.log4j.Logger;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

@Controller
public class SampleController {
	private static Logger log = Logger.getLogger(SampleController.class);
	@RequestMapping("sample")
	public String sample(@RequestParam(value="name",required=false,defaultValue="renwei") String name, Model model){
		log.debug("===============" + name);
		model.addAttribute("name", name);
		return "sample/sample";
	}
}
